package com.epam.training.formvalidate;

import java.util.Date;

import javax.validation.constraints.Future;
import javax.validation.constraints.NotNull;

import org.hibernate.validator.constraints.NotEmpty;
import org.springframework.format.annotation.DateTimeFormat;

public class BookingItemForm {
	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
	@Future
	@NotNull
	private Date issueDate;

	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
	@Future
	@NotNull
	private Date returnDate;

	@NotNull
	@NotEmpty
	private String issuePlace;

	@NotNull
	@NotEmpty
	private String returnPlace;

	@NotNull
	Integer car;

	@NotNull
	Integer insurance;

	/**
	 * @return the issueDate
	 */
	public Date getIssueDate() {
		return issueDate;
	}

	/**
	 * @param issueDate
	 *            the issueDate to set
	 */
	public void setIssueDate(Date issueDate) {
		this.issueDate = issueDate;
	}

	/**
	 * @return the returnDate
	 */
	public Date getReturnDate() {
		return returnDate;
	}

	/**
	 * @param returnDate
	 *            the returnDate to set
	 */
	public void setReturnDate(Date returnDate) {
		this.returnDate = returnDate;
	}

	/**
	 * @return the issuePlace
	 */
	public String getIssuePlace() {
		return issuePlace;
	}

	/**
	 * @param issuePlace
	 *            the issuePlace to set
	 */
	public void setIssuePlace(String issuePlace) {
		this.issuePlace = issuePlace;
	}

	/**
	 * @return the returnPlace
	 */
	public String getReturnPlace() {
		return returnPlace;
	}

	/**
	 * @param returnPlace
	 *            the returnPlace to set
	 */
	public void setReturnPlace(String returnPlace) {
		this.returnPlace = returnPlace;
	}

	/**
	 * @return the car
	 */
	public Integer getCar() {
		return car;
	}

	/**
	 * @param car
	 *            the car to set
	 */
	public void setCar(Integer car) {
		this.car = car;
	}

	/**
	 * @return the insurance
	 */
	public Integer getInsurance() {
		return insurance;
	}

	/**
	 * @param insurance
	 *            the insurance to set
	 */
	public void setInsurance(Integer insurance) {
		this.insurance = insurance;
	}

}
